Digital function generator

ABSTRACT

A digital function generator capable of generating any arbitrary single valued function representable by an independent and a dependent variable is disclosed. A state signal generator produces a plurality of output state signals corresponding to quantized sequential values of the independent variable. Predetermined ones of the quantized sequential signals correspond to predetermined incremental values of the dependent variable. A decoder monitors the output of the state signal generator and provides an output signal corresponding to the time of occurrence of the predetermined quantized sequential signals and the &#39;&#39;&#39;&#39;sense&#39;&#39;&#39;&#39; of the dependent variable change. A monitor provides an output signal which varies as a function of the decoder output. A digital-to-analog converter converts the monitor output to an analog signal representative of the function.

United States Patent [72] Inventors T. 0. Paine 3,483,364 12/1969 Leeson.... 235/197 Administrator of the National Aeronautics 3,486,0l8 12/1969 Warren 235/ l 97 and Space Administration with respect to 3,529,138 9/1970 Andre et al. 235/l50.53 an invention of;

Marvin Perlman Granada cam. Primary Examiner Malcolm A. MOll'lSOll 1 pp No 860 750 Assistant Examiner-Felix D. Gruber Filed Sept. 1969 Attorneys-J. H. Warden, Paul F. McCaul and G. T. McCoy [45] Patented Nov. 16, 1971 [54] DIGITAL FUNCTION GENERATOR ABSTRACT: A digital function generator capable of generat- 3 Claims, 2 Drawing Figs mg any arbitrary single valued function representable by an independent and a dependent variable l5 disclosed. A state [52] U.S.Cl 235/197, Signal generator produces a m m f output state i l 235/l50.52, 235/l50.53, 2 235/194. corresponding to quantized sequential values of the indepen- 340/347 R dent variable. Predetermined ones of the quantized sequential [51] Int. Cl G06g 7/26 Signa|s correspond to predetermined incremental values f h [50] Field of Search 235/l97, depgndem variable A decoger monitors he output of the state signal generator and provides an output signal corresponding to the time of occurrence of the predetermined [56] Re'erences Cited quantized sequential signals and the sense of the dependent UNITED STATES PATENTS variable change. A monitor provides an output signal which 3,l 10,802 11/1963 lngham et al. 235/l50.53 varies as a function of the decoder output. A digital-to-analog 3,345,505 l0/l967 Schmid 235/l97 converter converts the monitor output to an analog signal 3,435,l96 3/1969 Schmid 235/l97 representative ofthe function.

PATENTEnunv 16 I97] SHEET 1 [IF 2 DIGITAL FUNCTION GENERATOR ORIGIN OF THE INVENTION The invention described herein was made in the performance of work under a NASA contract and is subject to the provisions of Section 305 of the National Aeronautics and Space Act of 1958, Public Law 85-568 (72 Stat. 435; 42 USC 2457).

. BACKGROUND OF THE INVENTION 1.. Field of the Invention The present invention relates to digital function generators and mor'e'particularly to apparatus capable of accurately and repeatably generating arbitrary functions of a variable.

2: Description of the Prior Art There exists a requirement in certain applications to quickly, accurately and repeatably provide output signals corresponding to a preselected function of a variable. There is a further requirement to be able to readily expand or contract the function curve on a time and amplitude basis.

Known function generators may be classified in two groups; namely, those which utilize analog or digital techniques. Analog function generators sulTer from a variety of severe limitations. First, analog techniques are inherently limited in the range of curves they can produce. For example, an exponential function may be approximated by simply discharging a capacitor. However, more complex functions such as hyperbolic functions require devices approaching the complexity of an analog computer. For many applications such complex devices are prohibitively costly and cumbersome. Further, analog techniques result in inherently less accurate and less repeatable waveforms than do digital techniques. This is so since analog components, as is well known, are subject to nonuniform dynamic variations. in applications where system output information is dependent upon the driving function, for

example, as where the function is used to generate a sweep voltage for a mass s ectrometer, such nonrepeatability results in system errors which are difficult to isolate out.

Known digital function generators also suffer from a variety of defects. Known digital function generators utilize a variety of integration and differentiation techniques to derive the required function. Such approaches typically derive a signal approximating the line slope of the function at a plurality of spaced points and thence time integrate the approximation values to obtain the desired function. Such digital approaches are complex and require a large number of components. Further, since expanding or contracting the function inherently varies both the differential approximations and the accumulated integration values, such approaches do not readily lend themselves to simple function amplitude and width modification.

OBJECTS AND SUMMARY OF THE INVENTION In accordance with the present invention, there is provided a digital function generator capable of generating any arbitrary single valued function representable by an independent and a dependent variable.

A state signal generator produces a plurality of output state signals corresponding to quantized sequential values of the independent variable. In one embodiment, the quantized value representing signals are provided by the output of a feedback shift register cycled by a system clock which produces clock pulses at a preselectable rate. Varying the preselected clock rate provides a simple means of varying the quantized sequential independent value rate and thus the real time function width.

Predetermined ones of the quantized sequential value signals correspond to predetermined quantized sequential values of the dependent variable. A decoder monitors the output of the state signal generator and provides an output signal corresponding to the time of occurrence of the predetermined quantized sequential value signals and the sense of the dependent variable change. In one embodiment, the decoder is a diode-decoding matrix keyed to respond to predetermined shift register outputpatterns corresponding to the predetermined quantized value signals; The diode matrix is adapted to provide an output signal representative both of the time of occurrence of each predetermined quantized sequential value signal and of the sense" of the incremental dependent variable change required, that is whether the function is increasing or decreasing in value.

A monitor is provided which generates an output signal which varies as a function of the decoder output signal. The monitor output is therefore functionally related to the dependent variable. In one embodiment, the monitor is an up-down counter which responds to the matrix output signal to either step-up or stepdown the counter reading.

An analog signal generator responsive to the monitor output generates an analog signal corresponding to the desired function value. In one embodiment, the analog signal generator is a digital-to-analog converter. The converter output will vary in accordance with the function related output of the counter.

It is therefore an object of this invention to provide a digital function generator capable of accurately and repetitively generating an arbitrary variable width and amplitude function represented by an independent and dependent variable.

It is a further object of the invention to provide a digital function generator of simpler design than those generators heretofore known.

It is still a furtherobject of the present invention to provide a digital function generator capable of generating an arbitrary function which does not require any differentiation or integration components.

Still other objects, features and attendant advantages of the present invention will become apparent to those skilled in the art from a reading of the following detailed description of an embodiment constructed in accordance therewith taken in conjunction with the accompanying drawings and wherein:

BRIEF DESCRIPTION OF THE DRAWINGS DESCRIPTION OF THE PREFERRED EMBODIMENT Referring now to FIG. 1, an embodiment of a function generator constructed in accordance with the present invention is shown. In the implementation of the present invention equal changes of the dependent variable, small enough in value and in sufiicient number to reflect small changes in the curve representing the function, are made as a function of time in accordance with the desired shape of the curve. The approach may be appreciated having brief reference to FIG. 2 wherein the technique of approximating a hyperbolic function curve H, shown in dashed lines, is depicted. As illustrated, a hyperbolic function may be approximated by moving each'of the levels along the ordinate successively maintained for a selected period of time. Increments of time may be measured, as shown, along the abscissa.

Referring to FIG. 1, a feedback shift register 10 is shown having a plurality of output stages or leads X X,,. These output stages will individually assume either of two binary output levels and will collectively form a binary output pattern. Operation of the shift register I0 is for the purpose of cycling through all or a preselected number of these binary output patterns in synchronism with clock pulses from a system clock 11. The different binary output patterns of the feedback shift register 10 may be simply considered as multibit binary words and will hereinafter be referred to as output states. Feedback shift registers implemented according to a selected algorithm well known and need not be described in detail here. Such state of the art knowledge is exemplified by the textbook entitled Shift Register Sequences. by S. W. Golombs, copyright 1967, Holden-Day, Inc. A discussion of shift register sequences of all lengths is included therein at Part Ill, Chapter 7, Section 5.

The minimum number of output states required to accurately approximate a particular curve and thereby adequately describe a given function is determined from an analysis of each curve desired to be reproduced. Either a graphical analysis of the function curve or an algebraic analysis if the function can be algebraically expressed, may be used for this purpose.

In a graphic method, the curve such as the hyperbola H (FIG. 2) is laid out on rectangular coordinates. Parallel, equally spaced lines, exemplified by the lines 20, which are made sufficiently closely spaced to reflect small changes in the dependent variable i.e., values along the ordinate of the graph in FIG. 2, are drawn to intersect the curve H. Vertical lines 22, from the points where these parallel lines 20 intersect the curve are then drawn to the abscissa. The abscissa is then linearly scaled with a number of equal increments. As may be observed from the graph of FIG. 2, these equal increments correspond to clock pulse periods which should be made of sufficiently short duration to accommodate steep amplitude variations in the desired curve. as for example is true of the illustrated hyperbola H near the time IEO.

The number of shift register output stages, or bits in a binary output word, required to provide the minimum number of different binary output words or states may be determined from the equation:

SMpHZ" wherein 50 m is the number of unique output states required and *n" is the number of binary output shift register states required. For example, 600 different binary words would require the use of shift register stages or. otherwise considered. binary output words each including 10 bits.

In accordance with the present invention, time is correlated with the output states or binary output words of the shift register. It is to be understood that in accordance with the above discussion, each abscissa intersection point such as those found by the vertical lines 22 (FIG. 2) has associated therewith a unique shift register output state or binary output word. The abscissa intersection points may thus correspond to the times of occurrence of the selected unique output states within the entire sequence of output states of the feedback shift register.

A selection matrix 12, which functions as a decoder. receives the output of shift register 10. Selection matrix 12 is adapted to provide on an output lead I8 an enabling output to an AND-gate 13 when each preselected output state or binary output word is reached by shift register 10. Selection matrices adapted to provide outputs in accordance with a desired truth table function are well known, and need not be described in detail here. Selection matrix 12 may preferably be a diode matrix connected to provide an output which is the desired preselected Boolean function of the input provided by shift register 10.

The output ofselection matrix 12 is used to step an up-down counter 14 in the following manner. Whenever the feedback shift register 10 provides selection matrix 12 with one of the predetermined discrete output states corresponding to an abscissa intersection point as above described, the selection matrix supplies an enable pulse on line 18 to AND-gate l3. Andgate 13 further receives each clock pulse, as shown. When thus enabled, AND-gate 13 passes the pulse synchronously provided by clock II which is thereafter counted" by up-down counter 14. The diode matrix therefore serves to convert the nonweighted code of the feedback shift register to a series of nonuniformly spaced time pulses which are used to vary the counter reading.

The sense of the count, that is whether the pulse from And-gate I3 increments or decrements counter 14 is determined by a second output from selection matrix I2 which appears on line 19. The sense of the required dependent variable change at each intersection point is encoded into the selection matrix and is supplied as part of the Boolean transfer function of the matrix in a well-known manner.

Counter 14 is therefore continuously incremented or decremented under the control of the matrix 12 in order to produce the desired function. Counter 14 is "initialized" by initially reading in a binary number proportional to the desired initial value of the dependent variable i.e., measured along the ordinate FIG. 2. As a practical matter it is well known that this may be done by setting or resetting each of a number of bistable devices, such as flip-flops, that make up the counter. The same procedure would be applicable to initialize the shift register 10. The time history of the counter reading will therefore accurately represent the function desired to be generated.

A digital multiplier 15 continuously receives the output of counter 14. A digital-to-analog converter 16 receives the output of digital multiplier 15 and provides the analog equivalent of the binary digital multiplier output signals. Digital multiplier 15 is adapted to provide a binary output signal which is a predetermined multiple of the counter output signal. Varying the transfer ratio [output/input] of multiplier 15 allows the output waveform to be varied over any desired amplitude excursion.

Referring again to FIG. 2, the dashed curve H, as earlier discussed, represents a hyperbolic function or curve. The heavy solid lines may be taken to represent the digitally reproduced function H,, as generated by the apparatus of the present invention. As above described, equal changes in the dependent variable are held for varying time durations in accordance with desired shape of the curve. To generate the curve of FIG. 2, a nine-stage feedback shift register was caused to generate output states responsive to clock pulses in accordance with the feedback function: a =a s a 9 w where a denotes the content of the 5th stage (x,,) at clock pulse interval k; a denotes the content of the 9th stage (x,,) at clock pulse interval k;

a is the bit value which is fed back to stage x, at clock pulse interval k; and

Wis a specific word which is used to invert the bit value (a,

normally fed back to the first stage (.n) which has the effect of determining the total number of output states which the feedback shift register will cycle through. W will take on a value of I for one and only one output state.

This function states that the 5th and 9th binaries of the shift register and W are added modulo 2 (exclusive OR'ed) as follows:

State number (clock States Counter 11 11 I3 2:4 I5 16 1:1 1 1.; pulse) selected output 1 1 0 1 0 1 0 I lT 0 1 31 1 1 1 o 1 0 1 0 1 1 o T )0 1 I 1 0 1 0 I (I 2 1 30 T Excluslve-0Red' 40 0 0 I I l 0 I 0 4 I 20 l 0 0 0 1 I 1 0 l 5 0 0 1 O 0 0 I 1 1 O 6 I 28 0 0 1 0 l] 0 I I 1 7 1 O 0 1 (I 0 0 l I 8 0 l 1 0 0 1 0 0 0 1 It I 27 Shown in table I are the first 10 output states of the feedback shift register 10 that would be generated according to the feedback function of equation (2). The first state, namely 11010101], was used to initialize the register. The 275th state or binary output word namely lOlOlOl l l, was used to represent W, which as is indicated in table II, is the last selected binary output word and may be used to cause the re gister to cycle back to the initial state in any conventional fashion. The states or binary output words selected in accordance with the above discussion to decrement the counter are indicated by a 1" in the States selected column of table 1. A count of 31 was used to initialize the counter. Each selected state or binary output word thereafter decremented the counter reading, as shown.

The binary output words that were not selected i.e., l llOlOlOl, as is indicated by a 0" in the States Selected" column, simply occur without any further response. It may be noted from table I, however that each binary output word will occur at a particular position or time in the entire sequence of binary output words defined by a feedback function or algorithm such as equation (2). Consequently, since each binary word is clock pulse related and thus time related, as is shown by FIG. 2 and as was earlier discussed, the unselected binary output words or states may be viewed as incidentally serving to properly time space the selected states or binary output words. From table I and table ll, it may be further observed that the individual states or binary output words have no individual significance other than being selected for its order of occurrence within the entire sequence of states or binary output words defined by the algorithm.

It is thus to be noted that successive register output states or binary output words appear for fixed durations of time and at regular intervals as determined by the clock rate of the clock 11 whereas the selected states or binary output words are separated by time intervals in accordance with the desired curve.

The hyperbolic curve of FIG. 2 was represented by 32 selected binary output words formed by variable duration levels, as shown. The 32 nine-bit combinations and the corresponding state numbers, indicating order of occurrence appear in table ll. The decoding matrix 12 furnished an enabling pulse to the binary counter 14 via the AN D-gate 13 for each of these 32 selected shift register output states.

Up/down command 31 3O 29 28 27 26 25 24 23 22 21 19 18 17 16 16 14 13 12 ll 10 Table ll also shows the resultant counter reading for each selected state and the up-down sense command provided on line 19 ofselection matrix 12 (FIG. 1).

It will be appreciated that the counter 14 was continually decremented (indicated by an arbitrarily chosen 0" in the Up/Down Command" column) since the hyperbolic function of FIG. 2 is a monotonically decreasing function.

A nine-stage shift register is capable of providing a total of 512 discrete output states. To generate the function illustrated by FIG. 2, only 276 out of the possible 512 states were utilized. The remaining states were treated as don't cares and would have completed the sequence of different binary words defined by the feedback function of equation 2).

It may be readily appreciated by referring to FIG. 2 that the function width may be varied by simply varying the clock rate since the clock rate determines the real time occurrence of each output state. The analog output for any counter excursion may be varied by use of a proper multiplier transfer ratio.

I claim:

1. A function generator for providing a function signal representing a chosen function, the amplitude of said function signal representing values of said function at successively selected times, said function generator comprising:

a feedback shift register having a multiplicity of stages and adapted to be advanced through an expected sequence of different binary states, said shift register providing binary signals representing said different binary states at said stages;

matrix means. connected to receive said binary signals, for providing first and second matrix signals in response to preselected ones of said binary signals. said first matrix signal signifying the occurrence of a preselected binary signal, said second matrix signal providing a sense instructron;

a digital counter connected to receive said first and second matrix signals for providing a counter signal; said counter signal being changed in response to said first matrix signal, the direction of said change being controlled in accordance with said second matrix signal, whereby said counter signal is digitally proportional to said function signal;

and clock means. operatively connected to said feedback shift register and to said digital counter, for providing clock signals serving to advance said feedback shift register through said sequence of different binary states and serving to permit changes of said counter signal in synchronism with an advance by said feedback shift register.

2. The apparatus defined by claim 1 further including converter means for converting the digital form of said counter signal to a function signal of analog form.

3. The apparatus defined by claim 2 wherein the converter means includes a digital multiplier for altering the scale of said counter signals to be proportionally greater or lessor, the scale ofsaid function signals being correspondingly altered. 

1. A function generator for providing a function signal representing a chosen function, the amplitude of said function signal representing values of said function at successively selected times, said function generator comprising: a feedback shift register having a multiplicity of stages and adapted to be advanced through an expected sequence of different binary states, said shift register providing binary signals representing said different binary states at said stages; matrix means, connected to receive said binary signals, for providing first and second matrix signals in response to preselected ones of said binary signals, said first matrix signal signifying the occurrence of a preselected binary signal, said second matrix signal providing a sense instruction; a digital counter connected to receive said first and second matrix signals for providing a counter signal, said counter signal being changed in response to said first matrix signal, the direction of said change being controlled in accordance with said second matrix signal, whereby said counter signal is digitally proportional to said function signal; and clock means, operatively connected to said feedback shift register and to said digital counter, for providing clock signals serving to advance said feedback shift register through said sequence of different binary states and serving to permit changes of said counter signal in synchronism with an advance by said feedback shift register.
 2. The apparatus defined by claim 1 further including converter means for converting the digital form of said counter signal to a function signal of analog form.
 3. The apparatus defined by claim 2 wherein the converter means includes a digital multiplier for altering the scale of said counter signals to be proportionally greater or lessor, the scale of said function signals being correspondingly altered. 